From 4cab737e18d8d747de91611f40b511ee0882cac1 Mon Sep 17 00:00:00 2001 From: "kaf24@firebug.cl.cam.ac.uk" Date: Thu, 20 Apr 2006 17:02:42 +0100 Subject: [PATCH] SVM patch to ensure that PAE bit is set for 32bit guests on 32bit PAE, by using paging levels>=3 rather than ifdef i386. This patch fixes the "black screen" hang issue when building w/XEN_TARGET_X86_PAE=y on 32bit. Tested linux debian and win2003EE guests with pae=1. The linux guest boots without error, while the windows guest sometimes hits a bug() in shadow.c. Both VT and SVM encounter the same bug. Signed-off-by: Tom Woller --- xen/include/asm-x86/hvm/svm/vmcb.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/xen/include/asm-x86/hvm/svm/vmcb.h b/xen/include/asm-x86/hvm/svm/vmcb.h index 246144190c..24f9322b88 100644 --- a/xen/include/asm-x86/hvm/svm/vmcb.h +++ b/xen/include/asm-x86/hvm/svm/vmcb.h @@ -473,10 +473,10 @@ enum { #define VMCB_EFLAGS_RESERVED_1 0x00000002 /* bitmap for 1 */ /* These bits in the CR4 are owned by the host */ -#ifdef __i386__ -#define SVM_CR4_HOST_MASK (0) -#else +#if CONFIG_PAGING_LEVELS >= 3 #define SVM_CR4_HOST_MASK (X86_CR4_PAE) +#else +#define SVM_CR4_HOST_MASK 0 #endif -- 2.30.2